xend: Avoid unnecessary writes to xenstore.
authorkfraser@localhost.localdomain <kfraser@localhost.localdomain>
Fri, 17 Aug 2007 08:59:28 +0000 (09:59 +0100)
committerkfraser@localhost.localdomain <kfraser@localhost.localdomain>
Fri, 17 Aug 2007 08:59:28 +0000 (09:59 +0100)
Type of rtc/timeoffset is not 'int' but 'str'.
Signed-off-by: Kouya Shimura <kouya@jp.fujitsu.com>
tools/python/xen/xend/XendDomainInfo.py

index 3ca3f506d015f229fb8b5e103dd34db789a132b6..1a9622d002d6107711efb6020102facb5ccac80e 100644 (file)
@@ -981,7 +981,7 @@ class XendDomainInfo:
             changed = True
 
         # Check if the rtc offset has changes
-        if vm_details.get("rtc/timeoffset", 0) != self.info["platform"].get("rtc_timeoffset", 0):
+        if vm_details.get("rtc/timeoffset", "0") != self.info["platform"].get("rtc_timeoffset", "0"):
             self.info["platform"]["rtc_timeoffset"] = vm_details.get("rtc/timeoffset", 0)
             changed = True